home *** CD-ROM | disk | FTP | other *** search
/ Macworld Expo - Develope…Central & Net Innovations / Developer Central and Net Innovators (MacWorld Expo) (January 1999).iso / Developer Central / Bowers Development / Demo AppMaker / Examples / PowerPlant / AMReminder / DReminder.h < prev    next >
Encoding:
Text File  |  1998-10-11  |  1.8 KB  |  76 lines  |  [TEXT/CWIE]

  1. // DReminder -- data class for AMReminder
  2.  
  3. #pragma once
  4.  
  5. #include "AMDataDef.h"
  6.  
  7. class LFileStream;
  8.  
  9.  
  10. const long    idDateTime        = 'Date';
  11. const long    idMessage        = 'Mese';
  12. const long    idShowAlert        = 'Shot';
  13. const long    idShowIcon        = 'Shon';
  14. const long    idPlaySound        = 'Plad';
  15. const long    idSoundIndex        = 'Soux';
  16. const long    idDateString        = 'Datg';
  17. const long    idTimeString        = 'Timg';
  18. const long    idYearMonthDay        = 'Yeay';
  19. const long    idHourMinute        = 'Houe';
  20.  
  21.  
  22. //----------
  23. class DReminder : public AMDataDef {
  24. public:
  25.                 DReminder ();
  26.     virtual        ~DReminder ();
  27.  
  28. public:
  29.     void        CopyFrom        (DReminder*        inOther);
  30.     void        ReadFromFile    (LFileStream*        inFile);
  31.     void        WriteToFile        (LFileStream*        inFile);
  32.  
  33. public:        // accessors
  34.     LongDateRec        GetDateTime () const;
  35.     void        SetDateTime    (LongDateRec        inValue);
  36.  
  37.     StringPtr    GetMessage    (Str255        outStr = nil) const;
  38.     void        SetMessage    (ConstStringPtr    inValue);
  39.     void        SetMessage    (CharsHandle    inValue);
  40.  
  41.     Boolean        GetShowAlert () const;
  42.     void        SetShowAlert    (Boolean        inValue);
  43.  
  44.     Boolean        GetShowIcon () const;
  45.     void        SetShowIcon    (Boolean        inValue);
  46.  
  47.     Boolean        GetPlaySound () const;
  48.     void        SetPlaySound    (Boolean        inValue);
  49.  
  50.     SInt16        GetSoundIndex () const;
  51.     void        SetSoundIndex    (SInt16        inValue);
  52.  
  53.     StringPtr    GetDateString    (Str255        outStr = nil) const;
  54.     void        SetDateString    (ConstStringPtr    inValue);
  55.     void        SetDateString    (CharsHandle    inValue);
  56.  
  57.     StringPtr    GetTimeString    (Str255        outStr = nil) const;
  58.     void        SetTimeString    (ConstStringPtr    inValue);
  59.     void        SetTimeString    (CharsHandle    inValue);
  60.  
  61.     LongDateRec        GetYearMonthDay () const;
  62.     void        SetYearMonthDay    (LongDateRec        inValue);
  63.  
  64.     LongDateRec        GetHourMinute () const;
  65.     void        SetHourMinute    (LongDateRec        inValue);
  66.  
  67.  
  68. protected:
  69.     LongDateRec        mDateTime;
  70.     Str255        mMessage;
  71.     Boolean        mShowAlert;
  72.     Boolean        mShowIcon;
  73.     Boolean        mPlaySound;
  74.     SInt16        mSoundIndex;
  75. };
  76.